package com.ruibang.glass.purchase.service;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ruibang.glass.purchase.domain.req.PurchaseArrivalReq;
import com.ruibang.glass.purchase.entity.PurchaseArrivalOrders;
import com.ruibang.glass.purchase.entity.PurchaseArrivalProduct;
import com.ruibang.glass.purchase.entity.PurchaseReturns;

import java.util.List;

/**
 * <p>
 * 采购到货单表 服务类
 * </p>
 *
 * @author mameng
 * @since 2024-03-28
 */
public interface PurchaseArrivalOrdersService extends IService<PurchaseArrivalOrders> {
    /**
     * 质检新增 查询列表
     *
     * @param purchaseArrivalReq
     */
    IPage<PurchaseArrivalOrders> getPage(PurchaseArrivalReq purchaseArrivalReq);

    void checkQuality(PurchaseArrivalOrders purchaseArrivalOrders);

    void updateCheckResult(PurchaseArrivalOrders purchaseArrivalOrders);



    void deletePurchase(String id);

    /**
     * 质检新增 新建流程
     *
     * @param purchaseArrivalOrders
     */
    void addPurchaseArrivalOrders(PurchaseArrivalOrders purchaseArrivalOrders);

    void addPurchaseBack(PurchaseReturns purchaseReturns);

    PurchaseArrivalOrders getPurchaseArrivalOrders(String id);

    PurchaseArrivalOrders getReBackProduct(String id);

    String getArrivalOrderNumber();

    String getMaterialInNumber();

    /**
     * 获取原材料批次下拉
     *
     * @return
     */
    List<PurchaseArrivalOrders> getArrivalNumberList();

    List<PurchaseArrivalOrders> getOrderNumberList();

    List<PurchaseArrivalOrders> getSuppilerListByNumber(String number);

    List<PurchaseArrivalProduct> getOrderItemListById(String number);

    PurchaseArrivalProduct getProductInfoByNumberAndCode(PurchaseArrivalOrders purchaseArrivalOrders);

    List<PurchaseArrivalProduct> getBrocadeByNumberAndCode(PurchaseArrivalOrders purchaseArrivalOrders);

    List<PurchaseArrivalProduct> getBatchNumberByNumberAndCode(PurchaseArrivalOrders purchaseArrivalOrders);

    List<PurchaseArrivalProduct> getBatchNumber(String id);

    PurchaseArrivalOrders getCheckDetail(String id);
}
